package com.home.action;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.RequestMapping;

import com.home.model.Test;
import com.home.service.TestService;

@Controller
public class TestAction {
	@Autowired
	private TestService testService;
	
	@RequestMapping("/test.do")
	public String test(){
		Test t=new Test();
		t.setTest("ha");
		this.getTestService().insert(t);
		return "test";
	}

	public TestService getTestService() {
		return testService;
	}

	public void setTestService(TestService testService) {
		this.testService = testService;
	}
	
	
}
